package com.demo.strategy;

/**
 * 折扣策略
 */
public class DiscountStrategy implements Strategy {

    // 折扣率
    private double discount = 1.0;

    public DiscountStrategy(double discount) {
        this.discount = discount;
    }


    @Override
    public double priceCalculate(double money) {
        double result = money * discount;
        return result;
    }
}
